package com.central.scheduler.dao.mapper;

import com.central.db.mapper.SuperMapper;
import com.central.scheduler.dao.model.ProcessTaskRelation;
import com.central.scheduler.dao.model.ProcessTaskRelationLog;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author Tindy
 * @date 2021/11/5
 * @describe
 * process task relation mapper interface
 */
@Mapper
public interface ProcessTaskRelationLogMapper extends SuperMapper<ProcessTaskRelationLog> {



    /**
     * batch insert process task relation
     *
     * @param taskRelationList taskRelationList
     * @return int
     */
    int batchInsert(@Param("taskRelationList") List<ProcessTaskRelationLog> taskRelationList);
    /**
     * query process task relation log
     *
     * @param processCode process definition code
     * @param processVersion process version
     * @return process task relation log
     */
    List<ProcessTaskRelationLog> queryByProcessCodeAndVersion(@Param("processCode") long processCode,
                                                              @Param("processVersion") int processVersion);
}
